<?php


/**
 * Class Involved_WithdrawRecordModel
 */

class Involved_WithdrawRecordModel extends BaseModel
{

    protected $table = 'withdraw_record';

    /**
     * 获取提现记录列表
     */
    public function WithdrawRecordList(){
        return  DB::table($this->table)
            ->selectRaw('ypt_withdraw_record.withdraw_id,ypt_withdraw_record.bank_name,ypt_withdraw_record.bank_num,ypt_withdraw_record.withdraw_money,ypt_withdraw_record.status,ypt_withdraw_record.time,ypt_user.user_name as user_id')
            ->leftjoin('user','withdraw_record.user_id','=','user.user_id')
            ->get();
    }


    /**
     * 获取提现记录列表
     */
    public function GetWithdrawRecordOne($id){
        return  DB::table($this->table)
            ->where('withdraw_record.withdraw_id',$id)
            ->first();
    }
}